import { SELECT, CRUD } from '@/sheep/request/crud';
import { request } from '@/sheep/request';

const route = {
  path: 'category',
  name: 'shop.admin.category',
  component: () => import('@/app/shop/admin/category/index.vue'),
  meta: {
    title: '分类',
  },
};

const api = {
  ...CRUD('shop/admin/category'),
  select: (params) => SELECT('shop/admin/category', params),
  goodsSelect: (params) =>
    request({
      url: 'shop/admin/category/goodsSelect',
      method: 'GET',
      params,
    }),
};

export { route, api };
